/*
	Copyright (c) 2010 Canadensys
*/
package net.canadensys.dataportal.vascan;
import java.util.List;

import net.canadensys.dataportal.utils.HibernateUtil;

import org.hibernate.criterion.Restrictions;

public final class VernacularNameManager {
	@SuppressWarnings("unchecked")
	public static final List<VernacularName> findByName(String name){
		org.hibernate.Session hibernateSession = HibernateUtil.getSessionFactory().getCurrentSession();
		List<VernacularName> results = null;
		results = (List<VernacularName>) hibernateSession.createCriteria(VernacularName.class).add(Restrictions.eq("name", name)).list();
		return results;
	}
}
